package com.estore.manager;

import java.util.List;

import com.estore.entity.Categories;
import com.estore.entity.MainCategories;
import com.estore.entity.Product_Image;
import com.estore.info.BrandInfo;
//import com.estore.info.CatInfo;
import com.estore.info.ProductInfo;
import com.estore.info.SubCatInfo;

public interface ProductManager {

	public boolean checkCurrentCatName(Categories cat);
	
	public List<Categories> listAllCategories();
	
	public List<Categories> listCategories();
	
	public void addMainCategories(MainCategories main);
	
	public boolean checkMainCategories(MainCategories main);
	
	public List<MainCategories> getAllMainCategories();
	
	public MainCategories viewMainCategories(Integer mainCatID);
	
	public void editMainCategories(MainCategories mainCategories);

	public List<SubCatInfo> listSubCatInfo();

	public List<ProductInfo> getListProduct(int catID);

	public List<ProductInfo> getListAllProduct();

	public void addProduct(ProductInfo info);

	public void addBrand(String brandName, String website);

	public List<BrandInfo> getListBrand();

	public boolean checkBrandName(String brandName);

	public BrandInfo getBrandInfo(int brandID);

	public void updateBrand(int brandID, String brandName, String website);

	public void insertCategories(Categories cat);

	public Categories getCategories(Integer mainCatID);

	public boolean checkCategories(String catName);

	public void updateCategories(Categories info);

	public boolean checkProduct(String productName);

	// get top 12 newest product with categories name, brand name and img
	// display on homepage

	public List<ProductInfo> getTop12NewProduct();

	// list all product by sort type (newest =1 , hot = 2, discount = 3)

	public List<ProductInfo> getAllProduct(Integer sortType);

	// list product by cat

	public List<ProductInfo> getProductByCat(Integer catID);

	public ProductInfo getProductInfo(Integer ProductID, Integer imgType);

	public void editProductDetail(ProductInfo info);

	public boolean checkCurrentProductName(String productName, String productID);

	public void deleteImage(String linkImg, String productID);
	
	public boolean checkMainImg(String productID, String imgType);
	
	public void setMainImg(String productID, String imgType);
	
	public void addNewImg(List<Product_Image> listProductImg);
	
	public List<ProductInfo> fullTextSearchResult(String searchText);
	
	public List<ProductInfo> exactlySearchResult(String searchText);
	
	public String getAutoCompleteList();
	
	public List<ProductInfo> list12MostFavoriteProduct();
}
